package cn.zxf.note.user.addition;

import cn.zxf.note.common.web.AbstractController;
import cn.zxf.note.user.addition.dto.UserAdditionDto;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.server.ServerWebExchange;

/**
 * Created by zengxf on 2019/7/29.
 */
@RestController
@RequestMapping("/api/user/addition")
public class UserAdditionController extends AbstractController {

    @Autowired
    private UserAdditionService service;

    @GetMapping("find-one")
    public UserAdditionDto findOne(
            ServerWebExchange ex
    ) {
        return service.findOne(super.curUserId(ex));
    }

}
